package com.example.mapper;

import com.example.entity.SysStudent;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface SysStudentMapper {

    @Select("select * from sys_student where student_name = #{studentName}")
    SysStudent selectByName(String studentName);

    List<SysStudent> selectAll(SysStudent sysStudent);

    void insert(SysStudent sysStudent);

    void update(SysStudent sysStudent);

    @Delete("delete from `sys_student` where student_id=#{studentId}")
    void delete(Integer id);

    @Select("select * from sys_student where student_id = #{studentId}")
    SysStudent selectById(Integer studentId);
}
